package com.ym.domain.model;

import com.gitee.sunchenbin.mybatis.actable.annotation.ColumnComment;
import com.gitee.sunchenbin.mybatis.actable.annotation.ColumnType;
import com.gitee.sunchenbin.mybatis.actable.annotation.DefaultValue;
import com.gitee.sunchenbin.mybatis.actable.annotation.TableComment;
import com.gitee.sunchenbin.mybatis.actable.constants.MySqlTypeConstant;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Table;


@Data
@Table
@TableComment("域名实名模板")
@EqualsAndHashCode(callSuper = true)
public class DmRealNameTemplate extends BaseModel {

    //状态 : 0-待审核, 1-审核中, 2-审核成功, 3-审核拒绝
    public static final short STATUS_WAIT_CHECK = 0;
    public static final short STATUS_CHECKING = 1;
    public static final short STATUS_CHECK_SUCCESS = 2;
    public static final short STATUS_CHECK_FAIL = 3;

    // 模板类型
    public static final String TEMPLATE_TYPE_PERSON = "个人";
    public static final String TEMPLATE_TYPE_COMPANY = "企业";

    @Column
    @ColumnComment("客户ID")
    private Integer customerId;

    @Column(length = 100)
    @ColumnComment("模版名称")
    private String templateName;

    @Column
    @ColumnType(value = MySqlTypeConstant.CHAR, length = 2)
    @DefaultValue(value = "CN")
    @ColumnComment("国家代码，例如 CN 代表中国，US 代表美国。")
    private String country = "CN";

    @Column(length = 5)
    @ColumnComment("省份名称")
    private String province;

    @Column(length = 20)
    @ColumnComment("城市，填写域名持有者所在城市名称")
    private String city;

    @Column(length = 200)
    @ColumnComment("详细地址")
    private String address;

    @Column(length = 10)
    @ColumnComment("邮政编码")
    private String postalCode;

    @Column(length = 50)
    @ColumnComment("联系人名称")
    private String registrantName;

    @Column(length = 100)
    @ColumnComment("域名持有者名称")
    private String registrantOrganization;

    @Column(length = 20)
    @ColumnComment("电话号码")
    private String telephone;

    @Column(length = 5)
    @DefaultValue(value = "86")
    @ColumnComment("电话国家代码，例如中国的电话国家代码为 86。")
    private String telArea = "86";

    @Column(length = 10)
    @ColumnComment("分机号码")
    private String telExt;

    @Column(length = 10)
    @ColumnComment("模板类型:个人,企业")
    private String templateType;

    @Column(length = 255)
    @ColumnComment("个人/法人身份证照片(正面)")
    private String idImageFront;

    @Column(length = 255)
    @ColumnComment("个人/法人身份证照片(背面)")
    private String idImageBack;

    @Column(length = 20)
    @ColumnComment("身份证号码")
    private String idNo;

    @Column(length = 255)
    @ColumnComment("营业执照照片")
    private String licenseImage;

    @Column(length = 20)
    @ColumnComment("营业执照号码")
    private String licenseNo;

    @Column
    @ColumnComment("状态")
    private Short status;

    @Column
    @ColumnComment("是否默认")
    private Boolean isDefault;

    @Column(length = 200)
    @ColumnComment("身份证地址")
    private String idAddress;

}
